<?php

class Quad_Form_Element_Radio extends Quad_Form_Element_Option {
	
	public $selfClosing = true;
	
	public function __construct($labelText, $value='') {
		parent::__construct($labelText, $value);
		$this->type = 'radio';
		$this->_tagName = 'input';
		$this->addClassName('q-form-radio');
	}
	
	public function __toString() {
		$html = '<label>';
		$html .= $this->getOpenTag();
		$html .= ' <span class="q-label-text">' . $this->text . '</span>';
		$html .= '</label>';
		return $html;
	}
		
}

